package com.netafull.db;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

public class DBHelper extends SQLiteOpenHelper {

	private static final String DBNAME = "db_netafull";
	private static final int VERSION = 1;

	public DBHelper(Context context) {
		super(context, DBNAME, null, VERSION);

	}

	@Override
	public void onCreate(SQLiteDatabase db) {
		String sql = "create table mtb_category(_id integer primary key autoincrement,id integer,category_name varchar(255),title_count integer,img_flag integer)";
		db.execSQL(sql);
	}

	@Override
	public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
		db.execSQL("drop table if exists mtb_category");
		onCreate(db);
	}

}
